package com.dkt.android.api

import com.dkt.android.base.BaseRsps
import com.dkt.android.mvp.model.BackUserInfo
import com.dkt.android.mvp.model.IndexShopBean
import io.reactivex.Observable
import okhttp3.MultipartBody
import retrofit2.Response
import retrofit2.http.*


/**
 * @author: dtb
 * @email: wendaoyuqin1@gmail.com
 * @createTime: 19-3-14上午10:51
 */


object ApiC {

    //  url
//    const val API_USER = ""

    const val LOGIN = "login"
    const val ITEM_LIST = "item/list"
}

interface api {

    /**
     * user
     */

    @POST(ApiC.LOGIN)
    fun login(@Body multipartBody: MultipartBody)
            : Observable<Response<BaseRsps<BackUserInfo?>>>

    @GET(ApiC.ITEM_LIST)
    fun itemList( @Query("page") page:String, @Query("name") name:String)
            : Observable<Response<BaseRsps<List<IndexShopBean>>>>

}